package com.example.wechattakeaway.mapper;

import com.example.wechattakeaway.entity.DishOption;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;

import java.util.List;

@Mapper
@Repository
public interface DishOptionMapper {

    //删除选项
    int deleteByPrimaryKey(Integer dishOptionId);

    //插入菜品选项
    int insert(DishOption dishOption);

    int insertSelective(DishOption record);
    //根据id查询菜单选项
    DishOption selectByPrimaryKey(Integer dishOptionId);

    //修改菜品选项
    int updateByPrimaryKeySelective(DishOption dishOption);

    int updateByPrimaryKey(DishOption record);

    //根据菜品id查询菜品选项列表
    List<DishOption> selectByDishId(Integer dishId);
}